#!/bin/sh
##########################################################################
# This file is part of Hawkengine.
#
# Hawkengine is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Hawkengine is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
# along with Hawkengine.  If not, see <http://www.gnu.org/licenses/>.
##########################################################################

GENERATED_FILE="# Auto-Generated -- DO NOT EDIT"

ANDROID_MK=$ANDROID_PROJECT_DIR/$ANDROID_APP/jni/Android.mk

echo "$GENERATED_FILE" > $ANDROID_MK
echo "LOCAL_PATH:=\$(call my-dir)" >> $ANDROID_MK
echo "include \$(CLEAR_VARS)" >> $ANDROID_MK
echo "LOCAL_MODULE:=$ANDROID_APP" >> $ANDROID_MK
echo "LOCAL_SRC_FILES:=$ANDROID_SOURCES" >> $ANDROID_MK
echo "LOCAL_CFLAGS:=$ANDROID_CFLAGS" >> $ANDROID_MK
echo "LOCAL_LDLIBS:=$ANDROID_LDFLAGS" >> $ANDROID_MK
echo "LOCAL_STATIC_LIBRARIES:=$ANDROID_STATIC_LIBRARIES" >> $ANDROID_MK
echo "include \$(BUILD_SHARED_LIBRARY)" >> $ANDROID_MK
echo "\$(call import-module,android/native_app_glue)" >> $ANDROID_MK

APPLICATION_MK=$ANDROID_PROJECT_DIR/$ANDROID_APP/jni/Application.mk
echo "APP_PLATFORM := android-9" > $APPLICATION_MK

echo
echo Android preparation for $ANDROID_APP complete.
echo
